package com.dingup.mock.enums;

/**
 * Created by yanggavin on 16/3/16.
 */
public enum ExamContentTypeEnum {
    DEFAULT("default", "默认值"),
    LISTENING("listening", "听力"),
    SPEAKING("speaking", "口语"),
    READING("reading", "阅读"),
    WRITING("writing", "写作"),
    ALL("all", "整套练习");

    private String code;
    private String des;

    ExamContentTypeEnum(String code, String des) {
        this.code = code;
        this.des = des;
    }

    public String getCode() {
        return code;
    }
    public String getDes(){
        return des;
    }
    public static Boolean contains(String name){
        for (ExamContentTypeEnum e : values()){
            if (e.name().equals(name)){
                return true;
            }
        }
        return false;
    }
}
